import org.junit.Test;

import java.time.Instant;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.ZoneId;
import java.time.temporal.ChronoUnit;
import java.util.ArrayList;
import java.util.List;

/**
 * Author: linjx
 * Date: 2018/11/24
 */
public class Main {

    // hello
    private String slj;
    // getSlj
    private int getSlj;
    private String getSlj2;

    public static void main(String[] args) {
        long timestamp;
        timestamp = 1552457245;
        Instant instant = Instant.ofEpochMilli(timestamp * 1000);
        ZoneId zone = ZoneId.systemDefault();
        LocalDateTime endDate = LocalDateTime.ofInstant(instant, zone);
        long days = LocalDate.now().until(endDate.toLocalDate(), ChronoUnit.DAYS);
        System.out.println(days);
    }

    @Test
    public void test1() {
        String str = "亲爱的你好：\n你妹啊";
        System.out.println(str);
        List<Animal> list = new ArrayList<>();
        list.add(new Dog());
        System.out.println(list.get(0).getS());
    }

    class Animal {
        private String s;

        public String getS() {
            return s;
        }

        public void setS(String s) {
            this.s = s;
        }
    }

    class Dog extends Animal {
    }

    class SmallDog extends Dog {
    }

    class BigDog extends Dog {
    }

    class Cat extends Animal {
    }
}
